Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to FCS36 (and the SynType.Paren AST node :horror:) #899

Merged
merged 10 commits into from
Jun 12, 2020

Conversation

baronfel
Copy link
Contributor

@baronfel baronfel commented Jun 8, 2020

This one has some second-order effects. The addition of the simple branch to genType for wrapping the innerType of a SynType.Paren has got several tests failling due to double-parens. This should just mean that the addition of parens in those special-cased situations needs to be removed, but that hasn't proven the case just yet.

@@ -2395,7 +2395,10 @@ and genType astContext outerBracket t =

fun (ctx:Context) ->
isShortExpression ctx.Config.MaxRecordWidth shortExpression longExpression ctx

| TParen(innerT) ->
sepOpenT +>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in this case, to print a TParen, we render the parens around the rendering of the inner SynType.

@nojaf nojaf marked this pull request as ready for review June 12, 2020 12:04
@nojaf nojaf requested a review from jindraivanek June 12, 2020 12:04
@nojaf nojaf merged commit 11370c3 into fsprojects:master Jun 12, 2020
@nojaf
Copy link
Contributor

nojaf commented Jun 12, 2020

@baronfel, I released a new alpha with this:
https://www.nuget.org/packages/Fantomas/4.0.0-alpha-009

@baronfel
Copy link
Contributor Author

Thanks for finishing this up :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants